package com.yunyi.dm.singleton;

/**
 * 懒汉式
 * 线程安全
 *
 * @author yunyi
 */
public class LazyMode02 {

    private static LazyMode02 instance;

    public static synchronized LazyMode02 getInstance() {
        if (instance == null) {
            instance = new LazyMode02();
        }
        return instance;
    }

    private LazyMode02() {
    }
}
